
<script>
    var JiuXiaoView = {
        props:{
            dataList: {
                type: [Object, Array],
                default: () => {
                    return {};
                }
            },
            nextJob : {
                type: Object,
                default: () => {
                    return {};
                }
            },
        },
        template:`<div>
                    <template v-if="dataList.meansList && dataList.meansList.length">
                        <div class="list-item-mid" v-for="(item,inx) in dataList.meansList">
                            <span>{{initIssue(item.issue)}}期: </span>
                            <span class="green1-text">{{dataList.remarks}}</span>
                            <template v-if="item.means && item.means[0] && item.means[0].length">
                                <div v-for="(vl,vk) in item.means[0]" :key="vk">
                                    <span class="color-red" :class="{'bgcolor-yellow':vl.isTrue}" >{{vl.value}}</span>
                                </div>
                            </template>
                            <span>:开</span>
                            <span class="color-red" v-if="item.is_true == 0">？(00)</span>
                            <span class="color-red" v-else-if="item.drawp">{{item.drawp}}</span>
                            <span v-if="item.is_true == 1">中</span>
                            <span v-else-if="item.is_true == 2">错</span>
                            <span v-else>??</span>
                        </div>
                    </template>
                    <template v-else>
                        <div class="list-item-mid">
                            <span>{{nextList.issue}}期: </span>
                            <div v-for="i in nextList.len" :key="i">
                                <span class="color-red">？</span>
                            </div>
                            <template>
                                <span>:开</span>
                                <span class="color-red">？00</span>
                                <span>??</span>
                            </template>
                        </div>
                    </template>
                </div>`,
        data() {
            return {
                nextList:{}
            }
        },
        extends:moldExtend,
        mounted() {
            this.initNext();
        },
        methods: {
            initNext(){
                this.nextList = {
                    issue : '',
                    len : 6
                }
                if(this.dataList.lottery_alias && this.nextJob[this.dataList.lottery_alias] ) {
                    this.nextList.issue = this.nextJob[this.dataList.lottery_alias];
                }

                if(this.dataList.meansList && this.dataList.meansList.length && this.dataList.meansList[0].means && this.dataList.meansList[0].means.length && this.dataList.meansList[0].means[0]) {
                    this.nextList.len = this.dataList.meansList[0].means[0].length;
                }
            },
        }
    }
</script>